<%@page import="java.util.ArrayList"%>
<%@page import="java.util.HashMap"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8" errorPage="../err.jsp"%>
    <jsp:include page="../lock.jsp"></jsp:include>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>添加教室</title>
<style>
.txt20 {
	font-size: 20px;
}

.td {
	font-size: 18px;
	height: 50px;
	text-align: right;
}
.star{
	font-size:12px;
	color:red;
}
</style>
</head>
<body>
		<div class="txt20">当前位置-->添加教室</div>
	<%
			if (request.getAttribute("addparkinfo") != null) {
				out.print(request.getAttribute("addparkinfo"));
			}
		%>
		<form action="doaddpark.jsp" method="post">
			<table width="95%"  cellspacing="1" cellpadding="0" align="center" 
			style="background-color: azure">
			<tr>
				<td colspan="2" height="30px" >
				</td>
				</tr>
				<tr >
					<td class="td">教室编号：</td>
					<td><input type="text" name="ClassId"
						value="<%request.setCharacterEncoding("UTF-8");
			HashMap<String, String> formlist = new HashMap<String, String>();
			if (request.getAttribute("form") != null) {
				formlist = (HashMap<String, String>) request.getAttribute("form");
			}
			if (formlist.get("parknum") != null) {
				out.print(formlist.get("parknum"));
			}%>">
						<%
							ArrayList<Integer> errlist = new ArrayList<Integer>();
							if (request.getAttribute("info") != null) {
								errlist = (ArrayList<Integer>) request.getAttribute("info");
							}
							for (int i = 0; i < errlist.size(); i++) {
								if (errlist.get(i) == 1) {
									out.println("<span class=\"star\">*请输入车位编号。</span>");
									break;
								}
							}
						%></td>
				</tr>
				<tr>
					<td class="td">教室名称：</td>
					<td><input type="text" name="ClassName"
						value="<%if (formlist.get("parkposition") != null) {
				out.print(formlist.get("parkposition"));
			}%>">
						<%
							for (int i = 0; i < errlist.size(); i++) {
								if (errlist.get(i) == 2) {
									out.println("<span class=\"star\">*请输入车位位置。</span>");
									break;
								}
							}
						%></td>
				</tr>
				<tr>
					<td class="td">教室状态：</td>
					<td><input type="text" name="parktype"
						value="<%if (formlist.get("parkposition") != null) {
				out.print(formlist.get("parkposition"));
			}%>">
						<%
							for (int i = 0; i < errlist.size(); i++) {
								if (errlist.get(i) == 2) {
									out.println("<span class=\"star\">*请输入车位位置。</span>");
									break;
								}
							}
						%></td>
				</tr>
				<tr>
					<td class="td">教室座位：</td>
					<td><input type="text" name="Classstatus"
						value="<%if (formlist.get("parkposition") != null) {
				out.print(formlist.get("parkposition"));
			}%>">
						<%
							for (int i = 0; i < errlist.size(); i++) {
								if (errlist.get(i) == 2) {
									out.println("<span class=\"star\">*请输入车位位置。</span>");
									break;
								}
							}
						%></td>
				</tr>
				<tr>
					<td class="td">教室备注：</td>
					<td>
					<select name="Seatnumber">
					<option value="1" >良好</option>
					<option value="2">一般</option>
					
					</select>
					</td>
				</tr>
				<tr>
				<td></td>
					<td height="50px"><input type="submit" name="submit" value="提交" style="width:100px;height:25px"></td>
				</tr>
			</table>
		</form>
</body>
</html>